Skip to content

Conversation

@stephenswat
Copy link
Member

Currently, we could seed confirmations and add them to the weight of the seed. We add a large weight, 200, which causes several problems with the seeding code. Most prominently, our weights before the confirmation are in the range $[-10, 0]$ which means that adding 200 brings you in the range $[190, 200]$ and the minimum weight is 200. Thus, you are very coarsely cutting seeds on a very high minimum weight. Expressing the confirmations using an integer counting system makes us more robust against the aforementioned.

@stephenswat stephenswat added the refactor Change the structure of the code label Jul 28, 2025
@stephenswat
Copy link
Member Author

Depends on #1097.

@stephenswat stephenswat force-pushed the refactor/seed_confirmation_weighty branch 2 times, most recently from 16cd2fd to 0adad8c Compare July 29, 2025 12:01
@stephenswat
Copy link
Member Author

Performance summary

Here is a summary of the performance effects of this PR:

Graphical

Tabular

Kernel 327189d 0adad8c Delta
propagate_to_next_surface 42.29 ms 43.21 ms 2.2%
fit_forward 52.01 ms 43.15 ms -17.0%
fit_backward 26.39 ms 22.67 ms -14.1%
count_triplets 8.35 ms 8.34 ms -0.1%
find_triplets 4.44 ms 4.43 ms -0.2%
find_tracks 3.72 ms 3.20 ms -14.1%
count_doublets 1.75 ms 1.74 ms -0.5%
find_doublets 1.26 ms 1.27 ms 1.5%
ccl_kernel 871.15 μs 871.59 μs 0.1%
Thrust::sort 455.82 μs 446.77 μs -2.0%
fit_prelude 410.95 μs 415.87 μs 1.2%
select_seeds 349.76 μs 308.33 μs -11.8%
build_tracks 147.28 μs 113.58 μs -22.9%
find_triplet_confirmations 96.59 μs
apply_interaction 53.28 μs 51.08 μs -4.1%
fill_finding_propagation_sort_keys 34.96 μs 34.43 μs -1.5%
populate_grid 30.41 μs 30.46 μs 0.2%
count_grid_capacities 29.10 μs 29.20 μs 0.4%
estimate_track_params 34.47 μs 27.17 μs -21.2%
unknown 20.31 μs 20.42 μs 0.5%
fill_finding_duplicate_removal_sort_keys 18.60 μs 15.41 μs -17.2%
fill_fitting_sort_keys 2.26 μs 2.07 μs -8.1%
fill_prefix_sum 165.45 ns 165.51 ns 0.0%
update_triplet_weights 99.90 μs
remove_duplicates 394.37 μs 194.28 μs -50.7%
form_spacepoints 12.36 μs 12.50 μs 1.2%
reduce_triplet_counts 5.33 μs 5.37 μs 0.6%
make_barcode_sequence 1.01 μs 1.01 μs 0.5%
Total 143.17 ms 130.68 ms -8.7%

Important

All metrics in this report are given as reciprocal throughput, not as wallclock runtime.

Note

This is an automated message produced on the explicit request of a human being.

@stephenswat stephenswat force-pushed the refactor/seed_confirmation_weighty branch 2 times, most recently from 1170234 to 248ced1 Compare July 30, 2025 13:09
@stephenswat stephenswat marked this pull request as ready for review July 30, 2025 13:13
Currently, we could seed confirmations and add them to the weight of the
seed. We add a large weight, 200, which causes several problems with the
seeding code. Most prominently, our weights before the confirmation are
in the range [-10, 0] which means that adding 200 brings you in the
range [190, 200] and the minimum weight is 200. Thus, you are very
coarsely cutting seeds on a very high minimum weight. Expressing the
confirmations using an integer counting system makes us more robust
against the aforementioned.
@stephenswat stephenswat force-pushed the refactor/seed_confirmation_weighty branch from 248ced1 to 996af6b Compare July 30, 2025 13:14
@stephenswat
Copy link
Member Author

This is now ready. Reduces the number of seeds quite nicely while preserving the seeding efficiency:

test

@sonarqubecloud
Copy link

@stephenswat
Copy link
Member Author

Physics performance summary

Here is a summary of the physics performance effects of this PR. Command used:

traccc_seeding_example_cuda --input-directory=/data/Acts/odd-simulations-20240506/geant4_ttbar_mu200 --digitization-file=geometries/odd/odd-digi-geometric-config.json --detector-file=geometries/odd/odd-detray_geometry_detray.json --grid-file=geometries/odd/odd-detray_surface_grids_detray.json --use-detray-detector=on --input-events=10 --use-acts-geom-source=on --check-performance --truth-finding-min-track-candidates=5 --truth-finding-min-pt=1.0 --truth-finding-min-z=-150 --truth-finding-max-z=150 --truth-finding-max-r=10 --truth-finding-matching-ratio=0.7 --track-candidates-range=5:100 --seedfinder-vertex-range=-150:150

Seeding performance

Total number of seeds went from 354150 to 280992 (-20.7%)


Track finding performance

Total number of found_tracks went from 142164 to 123612 (-13.0%)


Note

This is an automated message produced on the explicit request of a human being.

@stephenswat stephenswat closed this Nov 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor Change the structure of the code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant